/*
* Copyright (C) 2020 ~ 2024 chaigec All Rights Reserved.
*
* Author:     chaigec <chaigec@163.com>
* Maintainer: chaigec <chaigec@163.com>

 * Use of this source code is governed by MIT license that can be found in the
 * LICENSE file in the root of the source tree. All contributing project authors
 * may be found in the AUTHORS file in the root of the source tree.
*/

#ifndef MK_RTSP_RESPONSE_H
#define MK_RTSP_RESPONSE_H
#include "MkRtspMessage.h"

class MkApi CMkRtspResponse :public CMkRtspMessage
{
public:
    CMkRtspResponse();
    ~CMkRtspResponse();
    const MkString& GetVersion() const { return m_Version; }
    const MkRtspStatusCode& GetStatusCode() const { return m_StatusCode; }
    const MkString& GetReasoon() const { return m_ReasonPhrase; }

    void SetStatusCode(const MkRtspStatusCode& StatusCode) { m_StatusCode = StatusCode; }
protected:
    virtual Uint32 OnPacketHeaderLine(OUT MkString& strHeader) override;
    virtual Uint32 OnParseHeaderLine(const MkString& strHeader) override;
private:
    //https://datatracker.ietf.org/doc/html/rfc2326#section-7.1
    MkString									m_Version;
    MkRtspStatusCode							m_StatusCode;
    MkString									m_ReasonPhrase;
};


#endif